#!/usr/bin/env python
# -*- coding:utf-8 -*-
# @Time: 2022/9/15 21:41
# @Author: 徐洪英
# @Email: xx@gmail.com
# @File：receivable_page.py


from selenium.webdriver.common.by import By
from config.config import HOST
from pages.base_page import BasePage
class CrmRiePage(BasePage):
    """类属性"""
    url="http://{}/crm/index.php?m=finance".format(HOST)
    rie_locator = (By.CSS_SELECTOR,"body > div.container > div.row > div:nth-child(1) > div.pull-right > a:nth-child(1)")#添加应收
    add_ys_locator = (By.CSS_SELECTOR, "body > div.container > div.row > div:nth-child(1) > div.pull-right > a:nth-child(2)")  # 添加应收单
    def click_add_rie(self):
        """点击添加应收"""
        self.driver.find_element(*self.rie_locator).click()
    def click_rie_list(self):
        """点击添加应收单"""
        self.driver.find_element(*self.add_ys_locator).click()
